﻿using System;
using System.Linq.Expressions;

namespace VisionCloud.Domain.Common
{
    public class AnyValidModel<T>
    {
        public Expression<Func<T, bool>> Express { get; set; }

        /// <summary>
        /// 是否抛出异常
        /// </summary>
        public bool ThrowException { get; set; } = true;

        /// <summary>
        /// 异常信息 ,ThrowException为ture时有效
        /// </summary>
        public string ErrorMessage { get; set; }
    }
}